<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="./vue.js"></script>
</head>

<body>
    <div class="wrap" id="demo">
        <div v-for="(item,index  in listData">
            name:{{item.name}} -- age:{{item.age}} -- id:{{item.id}} -- 下标{{index}}
        </div>
    </div>


</body>
<script>

    new Vue({
        el: '#demo',
        data: {
            listData: [
                { name: '张三', age: 20, id: '1' },
                { name: '李四', age: 40, id: '2' },
                { name: '王五', age: 60, id: '3' }
            ],
            ObjData: {
                name: '张三',
                age: 290,
                id: '1'
            }
        }
    })



</script>

</html>